Skip to content

DISCO-142: Print Only SDK Token to Stdout - #450

Merged
Patrick Tamunjoh (patricktamunjoh) merged 2 commits into
mainfrom
bugfix/DISCO-142-print-only-token-to-stdout
Nov 2, 2026
Merged

Patrick Tamunjoh (patricktamunjoh) merged 2 commits into
mainfrom
bugfix/DISCO-142-print-only-token-to-stdout

Conversation

@patricktamunjoh

Copy link
Copy Markdown
Contributor

Description

content-cli sdk token is meant to be captured in scripts, e.g. CELONIS_TOKEN=$(content-cli sdk token) npm install …. The banner and the beta notice were printed to stdout too, and -q only suppresses the banner. So the captured value wasn't a valid token and npm rejected it as an HTTP header. Diagnostics now go to stderr, so stdout carries only the command's output.

  • The banner is printed to stderr.
  • The console logger writes warn and error to stderr. This applies to every command, and keeps errors out of captured output.
  • Beta notices for commands and options are logged as warn, so they go to stderr together with the deprecation notice.
  • The sdk token docs no longer need -q. They show the app-scoped registry URL /api/codespace/apps/<appId>/npm/ with an .npmrc that reads the token from CELONIS_TOKEN.

Relevant links

@sonarqubecloud

sonarqubecloud Bot commented Nov 2, 2026

Copy link
Copy Markdown

Comment thread src/content-cli.ts Resolved
@patricktamunjoh
Patrick Tamunjoh (patricktamunjoh) merged commit 5a846b3 into main Nov 2, 2026
5 checks passed
@patricktamunjoh
Patrick Tamunjoh (patricktamunjoh) deleted the bugfix/DISCO-142-print-only-token-to-stdout branch November 2, 2026 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants